<template>
	<div class="history">
		<ul>
			<h2>浏览历史</h2>
			<li v-for="post in res" :key="post.id">
				<p>
					<router-link to="">
						{{post.title}}
					</router-link>
				</p>
			</li>
		</ul>
	</div>
</template>

<script>
	//模拟请求到的数据
	let reData = [{
			"id": "1",
			"title": "PHP学科:MySQL手册免费分享",
		},
		{
			"id": "2",
			"title": "前端必学框架Bootstrap,3天...",
		},
		{
			"id": "3",
			"title": "PHP进阶:要想提高PHP的编程...",
		},
		{
			"id": "4",
			"title": "这是第一篇文章",
		},
		{
			"id": "5",
			"title": "想少走弯路,就看看这个贴:PHP...",
		},
		{
			"id": "6",
			"title": "最涨薪PHP项目——PHP微信平台...",
		},

	]
	export default {
		data() {
			return {
				res: reData
			}
		}
	}
</script>

<style scoped>
	.history {
		background: #fff;
	}

	a {

		text-decoration: none;
		color: #000000;
	}

	li {
		text-align: left;
	}

	ul {
		padding: 0;
		list-style: none;
		margin-top: 18px;
	}
</style>
